1. Field of the Invention
The present invention relates to a demodulation device for demodulating a signal modulated with a data sequence encoded by using a predetermined scheme and a wireless device using the same demodulation device. More particularly, the present invention relates to an ASK (Amplitude Shift Keying) demodulation device for demodulating a signal (hereinafter referred to as a modulated signal) obtained by modulating a carrier which is ASK-modulated with a data sequence (Manchester data) obtained by Manchester-encoding NRZ (Non-Return to Zero) data, and a wireless device using the ASK demodulation device.
2. Description of the Background Art
Manchester encoding is a scheme of encoding data in which NRZ data “0” is mapped to “01” and NRZ data “1” is mapped to “10”. As such, in Manchester encoding, one bit is translated into a two-bit Code. Thus, there is always a level transition in the middle of each bit time of Manchester code. Note that, in Manchester encoding, NRZ data “0” may be mapped to “10” and NRZ data “1” may be mapped to “01”. However, in the following description, the former mapping rule in which NRZ data “0” is mapped to “01” and NRZ data “1” is mapped to “10” will be used. It will be understood that the latter mapping rule can also be used in the present invention.
An operation of a conventional ASK demodulation device for demodulating a modulated signal which is ASK-modulated with a Manchester-encoded data sequence will be briefly described. First, the conventional ASK demodulation device detects a modulated signal which is ASK-modulated with a Manchester-encoded data sequence by using a method such as synchronous detection or asynchronous detection (envelope detection), and obtains a detected signal. Next, the conventional ASK demodulation device compares the detected signal with a reference threshold value for determining which is greater, and obtains Manchester data which is a Manchester-encoded data sequence. Finally, the conventional ASK demodulation device performs Manchester decoding for the Manchester data, and outputs NRZ data, which is an NRZ-encoded data sequence, and a data clock signal which is a clock signal synchronized with the NRZ data. That is, other than Manchester decoding, the conventional demodulation device performs the same process as performed for demodulating a modulated signal which is ASK-modulated with an NRZ-encoded data sequence.
In general, a mean value of the detected signal is used as a threshold value for demodulating a modulated signal which is ASK-modulated with an encoded data sequence irrespective of whether the data sequence is encoded by NRZ encoding or Manchester encoding.
Also, Japanese Laid-Open Patent Publication No. 2000-78211 (patent document 1) discloses a technique in which a mean value of a maximum value and a minimum value of the detected signal is used as a threshold value for performing high-quality demodulation of ASK-modulated NRZ code.
In the case where a modulated signal which is ASK-modulated with an NRZ-encoded data sequence is demodulated, it is impossible for the conventional ASK demodulation device to calculate a correct threshold value if “0” or “1” is continuously inputted during a time period in which a mean value of the detected signal is obtained or a time period in which a mean value of a maximum value and a minimum value of the detected signal is obtained. Thus, the time period for obtaining a mean value has to be sufficiently longer than the bit time. However, too long time period for obtaining a mean value slows a response. As a result, in the case where a modulated signal which is ASK-modulated with an NRZ-encoded data sequence is demodulated, it is not impossible for the conventional ASK demodulation device to quickly change the threshold value in accordance with a level change of the detected signal.
On the other hand, in the case where a modulated signal which is ASK-modulated with a Manchester-encoded data sequence is demodulated, “0” and “1” are always included in one bit time. Thus, a conventional ASK demodulation device does not need to set a long time period for obtaining a mean value, compared to the case in which a modulated signal which is ASK-modulated with an NRZ-encoded data sequence is demodulated. As a result, it is easy for the conventional ASK demodulation device to change the threshold value in accordance with a level change of the detected signal.
FIG. 28 is a block diagram showing a structure of a conventional ASK demodulation device 90 disclosed in patent document 1. In FIG. 28, the conventional ASK demodulation device 90 includes an extreme value detection section 91, a moving average section 92, an averaging section 93, and a binarization calculating section 94. Hereinafter, an operation of the conventional ASK demodulation device when a modulated signal which is ASK-modulated with a Manchester-encoded data sequence is demodulated will be described. A detected signal obtained by detecting a modulated signal which is ASK-modulated with a Manchester-encoded data sequence by using a method such as synchronous detection or asynchronous detection is inputted to the ASK demodulation device 90. A threshold value used for comparison with the detected signal is calculated by the extreme value detection section 91, the moving average section 92, and the averaging section 93. The extreme value detection section 91 detects a maximum value and a minimum value of the inputted detected signal during a plurality of predetermined time periods, and inputs the detected values to the moving average section 92. The moving average section 92 obtains an average value of a plurality of minimum values in the plurality of predetermined time periods and an average value of a plurality of maximum values in the plurality of predetermined time periods, and inputs the resultant values, which are moving averages, to the averaging section 93. The averaging section 93 calculates an average value based on the moving average of the maximum values and the moving average of the minimum values, which are inputted from the moving average section 92, and inputs the resultant value to the binarization calculating section 94. The binarization calculating section 94 compares the detected signal with a threshold value outputted from the averaging section 93 for determining which is greater, and outputs Manchester data which is a Manchester-encoded data sequence. The Manchester data is a binary signal having “0” or “1”, and is inputted to a following Manchester decoding section (not shown). The Manchester decoding section performs clock recovery by detecting a change point of the Manchester data, and decodes Manchester code, thereby outputting NRZ data, which is an NRZ-encoded data sequence, and a data clock signal, which is a clock signal synchronized with the NRZ data. As such, the detected signal is demodulated.
Also, Japanese Laid-Open Patent Publication No. 2001-211214 (patent document 2) discloses a method of improving the duty ratio of Manchester data independent of the waveform of a detected signal. In this method, a threshold value is controlled based on Manchester data, and the controlled threshold value and the detected signal are compared for determining which is greater, thereby obtaining Manchester data. That is, a feedback loop is generated between a circuit for controlling a threshold value based on Manchester data and a circuit for comparing the threshold value with the detected signal for determining which is greater, whereby the threshold value is converged. As a result, the duty ratio is improved.
FIG. 29A is an illustration showing an eye pattern of a detected signal in the conventional ASK demodulation device 90 as shown in FIG. 28. FIG. 29B is an illustration showing an eye pattern of Manchester data in the conventional ASK demodulation device 90 as shown in FIG. 28. FIG. 29C is an illustration showing an eye pattern of Manchester data whose duty ratio is 50%. Hereinafter, with reference to FIGS. 29A, 29B, and 29C, the drawbacks of the conventional demodulation device 90 as shown in FIG. 28 will be described.
For instance, assume that a detected signal having an eye pattern as illustrated in FIG. 29A is inputted to the conventional ASK demodulation device. The horizontal axis represents time normalized by the bit time. The vertical axis represents signal amplitude. It is evident that the detected signal as shown in FIG. 29A is distorted and asymmetrical in that its upper portion is different from its lower portion in shape. In the case where a threshold value is obtained by the ASK demodulation device 90 as shown in FIG. 28, an average value of the maximum value and the minimum value of the detected signal is used as the threshold value. Thus, a value indicated by a dotted line in FIG. 29A is used as the threshold value. As a result, as illustrated in FIG. 29B, Manchester data with high jitter is obtained. Ideally, as illustrated in FIG. 29C, it is desirable to obtain Manchester data with 50% duty ratio. Here, the duty ratio is the ratio of a high-level period of the Manchester data to one bit time in the NRZ data. As illustrated in FIG. 29B, if the duty ratio of the Manchester data is not 50%, clock recovery is not stable in the Manchester decoding section. Thus, bit errors often occur when Manchester code is decoded. Similarly, even if the method using an average value of the detected signal as a threshold value is utilized, the duty ratio of the Manchester data may not be 50% when the detected signal is distorted.
Also, the method as disclosed in patent document 2 has the following drawback. In general, the feedback loop contains a trade off between changeability in a threshold value and loop stability to disturbance such as noise. Thus, the method as disclosed in patent document 2 has limitations in changing the threshold value quickly enough to deal with a case where a packet is received or the level of the detected signal is varied, for example. In order to concurrently achieve changeability and stability of a threshold value, the method as disclosed in patent document 2 additionally requires a complicated control circuit and fine adjustment thereof.
As such, the conventional ASK demodulation device adopting the method of comparing a detected signal with a threshold value for determining which is greater has the drawback that it is impossible to obtain the Manchester data with 50% duty ratio if the detected signal is distorted. Also, the conventional ASK demodulation device adopting the method of comparing a detected signal with a threshold value for determining which is greater has the drawback that a complicated control circuit for controlling the threshold value and fine adjustment of the control circuit are required to obtain the Manchester data with 50% duty ratio.